package com.stm.bi.dto.cmd;

import com.stm.bi.constant.DictionaryConstants;
import com.stm.framework.annotation.ReqParam;
import lombok.Data;
import lombok.experimental.Accessors;
import java.util.List;

/**
 * 科目-创建命令
 *
 * @author qinyongjie
 * @date 2025-05-22
 */
@Data
@Accessors(chain = true)
public class SubjectAdd {

    @ReqParam(label = "主键ID")
    private Long id;

    @ReqParam(label = "科目名称-每个租户可以有自己的同名科目，不会相互冲突", required = true, maxLength = 12)
    private String name;

    @ReqParam(label = "归属分类ID", required = true)
    private Long categoryId;

    @ReqParam(label = "参数类型-字典", dictType = DictionaryConstants.PARAM_TYPE)
    private String paramType;

    @ReqParam(label = "科目参数-字典-多选数组", dictType = DictionaryConstants.PARAM_TYPE)
    private List<String> subjectParam;

    @ReqParam(label = "科目定义", required = true, maxLength = 500)
    private String definition;

    @ReqParam(label = "科目标识", required = true, validateExp = "alpha")
    private String fieldName;
}
